+<?php
/**
 * TOP API: taobao.tbk.items.convert request
 * 
 * @author auto create
 * @since 1.0, 2014-04-09 17:23:20
 */
class TbkItemConvertRequest
{
   /** 
    * 需返回的字段列表.可选值:click_url
    **/
   private $fields;
   
   /** 
    * 推广者的淘宝会员昵称.注：指的是淘宝的会员登录名
    **/
   private $nick;
   
   /** 
    * 淘宝客商品数字id串.最大输入40个.格式如:"value1,value2,value3" 用" , "号分隔商品数字id
    **/
   private $numIids;
   
   /** 
    * 自定义输入串.格式:英文和数字组成;长度不能大于12个字符,区分不同的推广渠道,如:bbs,表示bbs为推广渠道;blog,表示blog为推广渠道.
    **/
   private $outerCode;
   
   /** 
    * 用户的pid,必须是mm_xxxx_0_0这种格式中间的"xxxx". 注意nick和pid至少需要传递一个,如果2个都传了,将以pid为准,且pid的最大长度是20。第一次调用接口的用户，推荐该入参不要填写，使用nick=（淘宝账号）的方式去获取，以免出错。
    **/
   private $pid;
   
   /** 
    * 点击串跳转类型，1：单品，2：单品中间页（无线暂无）
    **/
   private $referType;
   
   /** 
    * 商品track_iid串（带有追踪效果的商品id),最大输入40个,与num_iids必填其一
    **/
   private $trackIids;
   
   private $apiParas = array();
   
   public function setFields($fields)
   {
       $this->fields = $fields;
       $this->apiParas["fields"] = $fields;
   }

   public function getFields()
   {
       return $this->fields;
   }

   public function setNick($nick)
   {
       $this->nick = $nick;
       $this->apiParas["nick"] = $nick;
   }

   public function getNick()
   {
       return $this->nick;
   }

   public function setNumIids($numIids)
   {
       $this->numIids = $numIids;
       $this->apiParas["num_iids"] = $numIids;
   }

   public function getNumIids()
   {
       return $this->numIids;
   }

   public function setOuterCode($outerCode)
   {
       $this->outerCode = $outerCode;
       $this->apiParas["outer_code"] = $outerCode;
   }

   public function getOuterCode()
   {
       return $this->outerCode;
   }

   public function setPid($pid)
   {
       $this->pid = $pid;
       $this->apiParas["pid"] = $pid;
   }

   public function getPid()
   {
       return $this->pid;
   }

   public function setReferType($referType)
   {
       $this->referType = $referType;
       $this->apiParas["refer_type"] = $referType;
   }

   public function getReferType()
   {
       return $this->referType;
   }

   public function setTrackIids($trackIids)
   {
       $this->trackIids = $trackIids;
       $this->apiParas["track_iids"] = $trackIids;
   }

   public function getTrackIids()
   {
       return $this->trackIids;
   }

   public function getApiMethodName()
   {
       return "taobao.tbk.items.convert";
   }
   
   public function getApiParas()
   {
       return $this->apiParas;
   }
   
   public function check()
   {
       
       RequestCheckUtil::checkNotNull($this->fields,"fields");
       RequestCheckUtil::checkMaxListSize($this->numIids,50,"numIids");
       RequestCheckUtil::checkMaxListSize($this->trackIids,50,"trackIids");
   }
   
   public function putOtherTextParam($key, $value) {
       $this->apiParas[$key] = $value;
       $this->$key = $value;
   }
}